package com.you.modules.user.model;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Getter;
import lombok.Setter;

/**
 *<p>
 *用户表
 *</p>
 *
 * @author : liu.yang.
 * @date : 2018-07-08 星期日 18:08:41
 * @since : 1.0.0
 */
@Setter
@Getter
@TableName("user_info")
public class UserInfo extends Model<UserInfo> {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    private Integer id;
    /**
     * 用户id
     */
    private String uid;
    /**
     * 用户名
     */
    private String username;
    /**
     * 密码
     */
    private String password;
    /**
     * 性别(1:男,2:女)
     */
    private Integer sex;
    /**
     * 昵称
     */
    private String nickname;
    /**
     * 手机号码
     */
    private String phone;
    /**
     * 邮箱
     */
    private String email;
    /**
     * 用户类型(1.管理员，2:普通用户)
     */
    private Integer type;
    /**
     * 生日
     */
    private Date birthday;

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "UserInfo{" +
        "id=" + id +
        ", uid=" + uid +
        ", username=" + username +
        ", password=" + password +
        ", sex=" + sex +
        ", nickname=" + nickname +
        ", phone=" + phone +
        ", email=" + email +
        ", type=" + type +
        ", birthday=" + birthday +
        "}";
    }
}
